package cn.edu.sjtu.se.dslab.dao;

import java.util.List;

import cn.edu.sjtu.se.dslab.action.bean.PageBean;
import cn.edu.sjtu.se.dslab.component.method.ComponentInterface;
import cn.edu.sjtu.se.dslab.exception.DBException;

public interface IComponentInterfaceDao {
	public void save(ComponentInterface componentInterface);

	public boolean delete(ComponentInterface componentInterface);
	
	public boolean deleteById(long id);
	
	public boolean deleteByUri(String uri);
	
	public void update(ComponentInterface componentInterface);

	public ComponentInterface queryById(long id);

	public ComponentInterface queryByUri(String uri);
	
	public List<ComponentInterface> queryByProperty(String text);
	
	public List<ComponentInterface> queryByType(String type);

	public List<ComponentInterface>  queryAll();
	
	public PageBean<ComponentInterface> queryByPageNum(int pageNo) throws DBException;
	
	public boolean checkUri(String uri);
}
